package cz.uhk.max.matrix;

import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;


public class Row {
	private List<Col> cols = new ArrayList<Col>();
	private int colsCount;
	private boolean eliminated;

	public Row() {
	}

	public Row(Row rowA) {
		colsCount = rowA.getColsCount();
		for (int j = 0; j < colsCount; j++) {
			cols.add(new Col(rowA.getCols().get(j).getValue()));
		}
	}
	
	public Row(int rowIndex, int colsCount) {
		//VYTVO�� SE JEDEN NOV� ��DEK
		//konstruktor kter� ulo�� k objekt�m Col tak� jejich index
		this.colsCount = colsCount;
		for (int j = 0; j < colsCount; j++) {
			cols.add(new Col(rowIndex,j));
		}
	}
	
	public Row(int colsCount) {
		this.colsCount = colsCount;
		for (int i = 0; i < colsCount; i++) {
			cols.add(new Col());
		}
	}

	public void setCols(List<Col> cols) {
		this.cols = cols;
	}

	public List<Col> getCols() {
		return cols;
	}

	public void setColsCount(int colsCount) {
		this.colsCount = colsCount;
	}

	public int getColsCount() {
		return colsCount;
	}

	public void setEliminated(boolean eliminated) {
		this.eliminated = eliminated;
	}

	public boolean isEliminated() {
		return eliminated;
	}

}
